﻿///<copyright>
/// Copyright © 2009 Stephen Styrchak. All Rights Reserved.
/// Portions copyright (C) Microsoft Corporation. All rights reserved.
///</copyright>
using System;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace Ferpect.ComponentModel.Sprites
{
    public class ExplosionSmokeParticlesSprite : ParticlesSprite
    {
        public ExplosionSmokeParticlesSprite()
        {
            // less initial speed than the explosion itself
            MinInitialSpeed = 20;
            MaxInitialSpeed = 200;

            // acceleration is negative, so particles will accelerate away from the
            // initial velocity.  this will make them slow down, as if from wind
            // resistance. we want the smoke to linger a bit and feel wispy, though,
            // so we don't stop them completely like we do ExplosionParticleSystem
            // particles.
            MinAcceleration = -10;
            MaxAcceleration = -50;

            // explosion smoke lasts for longer than the explosion itself, but not
            // as long as the plumes do.
            MinLifetime = 1.0f;
            MaxLifetime = 2.5f;

            MinScale = 1.0f;
            MaxScale = 2.0f;

            MinNumParticles = 10;
            MaxNumParticles = 20;

            MinRotationSpeed = -MathHelper.PiOver4;
            MaxRotationSpeed = MathHelper.PiOver4;

            BlendState = BlendState.AlphaBlend;
        }
    }
}
